home *** CD-ROM | disk | FTP | other *** search
- <?xml version="1.0" encoding="utf-8" ?>
- <!DOCTYPE stack PUBLIC "-//Apple, Inc.//DTD stack V 2.0//EN" "" >
- <stack>
- <name>in</name>
- <id>-1</id>
- <cardCount>13</cardCount>
- <cardID>4144</cardID>
- <listID>3862</listID>
- <cantModify><false /></cantModify>
- <cantDelete><false /></cantDelete>
- <cantAbort><false /></cantAbort>
- <cardSize>
- <width>512</width>
- <height>342</height>
- </cardSize>
- <script>on openstack
- go to card Index
- global prioruserlevel
- get the userLevel
- put it into prioruserlevel
- set the userLevel to 5
- -- create the menus
- -- keep the "handles" to the menus in these globals
- global menu1
- put NewMenu("XrefText/M","Go To Reference","Create Reference",¬
- "(-","Back Up","Back To Index","(-","New XrefText Stack",¬
- "Toggle Picture","Import Text","Output","(-","XrefText-M Help")into menu1
- if menu1 is 0 then answer("Unable to make menu 'BEEP'") with "Drat"
- end openstack
-
- on closestack
- global prioruserlevel
- set the userLevel to prioruserlevel
- set the loc of msg to 22,300
- -- delete the menus we've created using
- --the globals saved in openStack
- global menu1
- put DeleteMenu(menu1) into menu1
- -- clearing global for safety
- end closestack
-
- on doMenu which
- -- get our menu items from doMenu before HyperCard does...
- global menu1, menu2
- -- for CheckMenu and EnableMenu below
- if which is "Go To Reference" then
- put the selection into holder
- push card
- visual effect wipe right to black
- visual effect wipe left
- find holder in field keywords
- if the result is not empty then
- answer "No match for keyword " "e& holder"e
- pop card
- end if
- else if which is "Create Reference" then
- put the selection into holder
- type ">" & holder & "<"
- push card
- find holder in field keywords
- if the result is not empty then
- doMenu New Card
- put holder into field keywords
- set the name of this card to holder
- get the number of lines in card field finder of card theIndex
- put holder into line it+1 of card field finder of card theIndex
- else
- put the length of holder into hl
- put the length of word 1 of field keywords into kl
- if hl<>kl then
- answer "Close match but not exact!" with "Good Enough" or¬
- "New Card"
- if it contains "New" then
- set lockscreen to true
- go prev
- doMenu New Card
- put holder into field keywords
- set the name of this card to holder
- get the number of lines in card field finder of card theIndex
- put holder into line it+1 of card field finder of card theIndex
- set lockscreen to false
- end if
- end if
- end if
- else if which is "Back Up" then
- if the number of this card = 1 then
- answer "Careful. You might leave this stack." with Cancel or OK
- if it = "OK" then
- visual effect wipe left to black
- visual effect wipe right
- go back
- else
- exit doMenu
- end if
- else
- visual effect wipe left to black
- visual effect wipe right
- pop card
- end if
- else if which is "Back To Index" then
- if the number of this card > 1 then
- -- visual effect wipe down to black
- visual effect iris close to white
- visual effect dissolve
- go to first card
- else
- play boing
- answer "You're already at the first card!"
- end if
- else if which is "XrefText-M Help" then
- visual effect dissolve
- go card ayuda
- else if which is "Toggle Picture" then
- if the number of this card > 2 then
- answer "Change to Picture or Text?" with Text or Picture
- if it contains "Text" then
- show tool window
- choose select tool
- doMenu Select All
- doMenu Clear Picture
- choose browse tool
- hide tool window
- hide pattern window
- else
- show pattern window
- show tool window
- choose rectangle tool
- set filled to false
- drag from (item 1 of the rect of field keywords), (item 2 of the¬
- rect of field keywords) to (item 3 of the rect of field¬
- keywords), (item 4 of the rect of field keywords)
- drag from 0,28 to 512,342
- choose bucket tool
- set pattern to 1
- click at 250,250
- choose text tool
- set the textfont to Geneva
- set the textsize to 9
- click at 10,320
- type "Don't use eraser. Use white brush instead."
- click at 10,330
- type "Choosing Browse Tool will show XrefText/M menu."
- choose brush tool
- end if
- else
- play boing
- answer "Uh-uh. You don't want to change this card."
- end if
- else if which is "Import Text" then
- if the number of this card &g